export default interface DashboardComponentType<T> {
  //基本属性

  //id
  id: string;

  //名称
  name: string;

  //中文标签
  label: string;

  //唯一标识
  compId?: string;

  //组件分组
  group: string;

  //图层类型
  layerType: string;

  //层级
  level: number;

  //是否激活
  active: boolean;

  //属性组件
  propertyComponent: string;

  //组件样式生成器
  componentStyleGeneratorName: string;

  //尺寸
  componentDimensions: {
    width: number;
    height: number;
  };

  //位置
  componentPosition: {
    top: number;
    left: number;
  };

  //样式属性
  styleProps?: {
    backgroundImage?: string;
    backgroundColor?: string;
    backgroundRepeat?: string;
    backgroundSize?: string[];
    backgroundPosition?: string[];
    borderTop?: {
      color: string;
      width: number;
      style: string;
    };

    borderBottom?: {
      color: string;
      width: number;
      style: string;
    };

    borderLeft?: {
      color: string;
      width: number;
      style: string;
    };

    borderRight?: {
      color: string;
      width: number;
      style: string;
    };

    transformRotate?: number;
    transformScale?: number;

    fontSize?: number;
    color?: string;
    fontStyle?: string;
    fontWeight?: number;
    textDecoration?: string;
    textShadowList?: Array<{
      hShadow: number;
      hShadowUnit: string;
      vShadow: number;
      vShadowUnit: string;
      blur: number;
      blurUnit: string;
      color: string;
    }>;
  };

  //组件属性
  componentProps?: T;

  //子节点
  children?: DashboardComponentType<T>[];

  //非结构化数据（辅助逻辑控制用的）
  unstructuredData?: {
    //是否编辑中文标签
    isEditLabel?: boolean;
  };
}
